﻿
using System;
using System.Net;
using System.Windows;
using System.Windows.Controls;
using System.Windows.Documents;
using System.Windows.Ink;
using System.Windows.Input;
using System.Windows.Media;
using System.Windows.Media.Animation;

using System.Windows.Shapes;
using Sqo;

namespace Ivvy_Silverlight
{


    /// [Generated Jan 31 2011]

    public partial class i_CalendarItemRecurrence : ISqoDataObject
    {

        #region "private fields"

        private int _CalendarItemRecurrence_ID;
        private int _CalendarItem_ID;
        private string _RecurrencePattern;

        #endregion

        #region "public properties"

        public int CalendarItemRecurrence_ID
        {
            get { return _CalendarItemRecurrence_ID; }
            set { _CalendarItemRecurrence_ID = value; }
        }
        public int CalendarItem_ID
        {
            get { return _CalendarItem_ID; }
            set { _CalendarItem_ID = value; }
        }
        public string RecurrencePattern
        {
            get { return _RecurrencePattern; }
            set { _RecurrencePattern = value; }
        }

        #endregion

        #region "ISqoDataObject"
        object ISqoDataObject.GetValue(System.Reflection.FieldInfo field) { return field.GetValue(this); }
        void ISqoDataObject.SetValue(System.Reflection.FieldInfo field, object value) { field.SetValue(this, value); }

        int ISqoDataObject.OID { get { return CalendarItemRecurrence_ID; } set { } }
        #endregion

        #region "MAPPER"
        public static Ivvy_Silverlight.i_CalendarItemRecurrence Convert(i7SR.CalendarItemRecurrence od_CalendarItemRecurrence)
        {
            return new Ivvy_Silverlight.i_CalendarItemRecurrence()
            {

                CalendarItemRecurrence_ID = Utils.IsNull(od_CalendarItemRecurrence.CalendarItemRecurrence_ID),
                CalendarItem_ID = Utils.IsNull(od_CalendarItemRecurrence.CalendarItem_ID),
                RecurrencePattern = Utils.IsNull(od_CalendarItemRecurrence.RecurrencePattern),

            };
        }
        #endregion


        #region "REVERSEMAPPER"
        public static Ivvy_Silverlight.i7SR.CalendarItemRecurrence ReverseConvert(i_CalendarItemRecurrence od_CalendarItemRecurrence)
        {
            return new Ivvy_Silverlight.i7SR.CalendarItemRecurrence()
            {

                CalendarItemRecurrence_ID = Utils.ReverseIsNull(od_CalendarItemRecurrence.CalendarItemRecurrence_ID).Value,
                CalendarItem_ID = Utils.ReverseIsNull(od_CalendarItemRecurrence.CalendarItem_ID),
                RecurrencePattern = Utils.ReverseIsNull(od_CalendarItemRecurrence.RecurrencePattern),

            };
        }
        #endregion

    }
}

